<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>The __construct purpose</title>
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-base.css" />
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-medium.css" />

 </head>
 <body class="docs"><div class="navbar navbar-fixed-top">
  <div class="navbar-inner clearfix">
    <ul class="nav" style="width: 100%">
      <li style="float: left;"><a href="mongo.connectutil.html">« Mongo::connectUtil</a></li>
      <li style="float: right;"><a href="mongo.getpoolsize.html">Mongo::getPoolSize »</a></li>
    </ul>
  </div>
</div>
<div id="breadcrumbs" class="clearfix">
  <ul class="breadcrumbs-container">
    <li><a href="index.html">PHP Manual</a></li>
    <li><a href="class.mongo.html">Mongo</a></li>
    <li>The __construct purpose</li>
  </ul>
</div>
<div id="layout">
  <div id="layout-content"><div id="mongo.construct" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">Mongo::__construct</h1>
  <p class="verinfo">(PECL mongo &gt;=0.9.0)</p><p class="refpurpose"><span class="refname">Mongo::__construct</span> &mdash; <span class="dc-title">The __construct purpose</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-mongo.construct-description">
  <h3 class="title">Description</h3>
  <div class="constructorsynopsis dc-description">
   <span class="modifier">public</span> <span class="methodname"><strong>Mongo::__construct</strong></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$server</code><span class="initializer"> = ?</span></span>, <span class="methodparam"><span class="type">array</span> <code class="parameter">$options</code><span class="initializer"> = ?</span></span>)</div>

  <p class="para rdfs-comment">
  This method overwrites the <a href="class.mongoclient.html" class="classname">MongoClient</a> constructor
  and turns off acknowledged writes.
  </p>
  <p class="para">
   Please see <span class="methodname"><a href="mongoclient.construct.html" class="methodname">MongoClient::__construct()</a></span> for
   description of the parameters.
  </p>
 </div>


 <div class="refsect1 errors" id="refsect1-mongo.construct-errors">
  <h3 class="title">Return Values</h3>
  <div class="warning"><strong class="warning">Warning</strong>
   <p class="para">
    Instanciating this class will emit <strong><code>E_DEPRECATED</code></strong>
    warning, and turn off acknowledged writes.
   </p>
  </div>
  <p class="para">
   Please use the <a href="class.mongoclient.html" class="classname">MongoClient</a> instead.
  </p>
 </div>



</div></div></div></body></html>